package com.autumn.zero.authorization.application.dto.users;

import com.autumn.util.excel.annotations.ExcelColumn;
import com.autumn.util.excel.annotations.ExcelWorkbook;
import com.autumn.zero.authorization.constants.LoginResultConstants;

/**
 * 
 * 用户登录尝试输出
 * 
 * @author 杨昌国 2018-12-11 15:39:01
 */
@ExcelWorkbook(exportTitle = "用户登录尝试")
public class UserLoginAttemptOutput extends UserLoginLogOutput {

	/**
	 * 
	 */
	private static final long serialVersionUID = 3299885040801240276L;

	/**
	 * {@link com.autumn.zero.authorization.constants.LoginResultConstants}
	 */
	private Integer loginResult;

	/**
	 * 获取登录结果
	 * 
	 * @return {@link com.autumn.zero.authorization.constants.LoginResultConstants}
	 */
	public Integer getLoginResult() {
		return loginResult;
	}

	/**
	 * 设置登录结果
	 * 
	 * @param loginResult {@link com.autumn.zero.authorization.constants.LoginResultConstants}
	 */
	public void setLoginResult(Integer loginResult) {
		this.loginResult = loginResult;
	}

	/**
	 * 获取登录结果名称
	 * 
	 * @return
	 */
	@ExcelColumn(order = 20, friendlyName = "登录结果", width = 80)
	public String getLoginResultName() {
		return LoginResultConstants.getName(this.getLoginResult());
	}
}
